<?php
namespace app\helper;

use Tinywan\Jwt\JwtToken;

class JwtHelper
{
    private const ACCESS_TOKEN = 1;

    public static function encode($payload)
    {
        return JwtToken::generateToken($payload);
    }

    public static function decode($token)
    {
        return JwtToken::verify(self::ACCESS_TOKEN, $token);
    }
} 